"""
Views which allow users to create and activate accounts.

"""

from django.conf import settings
from django.core.urlresolvers import reverse
from django.http import HttpResponseRedirect
from django.shortcuts import render_to_response
from django.template import RequestContext
from google.appengine.ext import db

def get(self):
    greeting = db.get(self.request.get("img_id"))
    if greeting.avatar:
        self.response.headers['Content-Type'] = "image/png"
        self.response.out.write(greeting.avatar)
    else:
        self.response.out.write("No image")